package com.zhuangyuan.cloud.data.service;

import com.zhuangyuan.cloud.data.entities.Category;

import java.util.List;
import java.util.Map;

public interface CategoryService extends BaseService{
    List<Category> list();
    List<Category> list(int level);
    List<Category> children(String id);
    Category add(Category c);
    List<Category> addAll(List<Category> categories);
    boolean delete(String id) throws Exception;

    boolean exists(Map<String,Object> propertyValue) throws Exception;
    boolean hasChild(String id);
    boolean canDelete(String id);
}
